home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / MacApp Release 10 / MacApp Release 10 - HD Ready / UserStartup•MacApp < prev   
Encoding:
Text File  |  1996-04-03  |  1.5 KB  |  36 lines  |  [TEXT/MPS ]

  1. # UserStartup•MacApp
  2. # Copyright © 1986-96 by Apple Computer, Inc. All rights reserved.
  3. #
  4. # Drop this file in your MPW Folder
  5.  
  6. #    Change History:
  7. #         4/17/95    TWB        Restore exit to its previous value instead of setting it to 1. 
  8. #        11/10/94    TWB        It's ok if there are any items in the Startup folder. 
  9. #                            Don't require the startup file to be named "Startup". 
  10.  
  11. #    Set the location of the MacApp Folder
  12. # If the folder can't be found; automatically prompts user for it and
  13. # remember where the folder was found
  14.  
  15. if  ¬ "{MacApp}" && "`Exists "{ShellDirectory}"MacApp_Folder`" 
  16.     Set MacApp     "`Catenate "{ShellDirectory}"MacApp_Folder`"
  17. End
  18. if ¬ "`Exists "{ShellDirectory}"MacApp_Folder`" || ¬ "`Exists "{MacApp}"`"
  19.     Set SaveExit "{exit}"; Set exit 0; Set temp "{Boot}"; Loop; ∂
  20.     Set temp "`(GetFileName "{temp}" -q -d -m "Where is your ∂"MacApp∂" folder?")≥dev:null`"; ∂
  21.     if "{temp}"!=""; Echo -n "{temp}" > "{ShellDirectory}"MacApp_Folder; ∂
  22.     Set MacApp "{temp}"; Else; exit; End; ∂
  23.     (set x "`Files "{temp}Startup Items:"`") ≥dev:null; ∂
  24.     if  "{x}"==""; Alert MacApp - The ∂"{temp}∂" folder does not contain MacApp files.; else; break; end; End; ∂
  25.     set exit "{SaveExit}"; unset SaveExit;
  26. End
  27.  
  28. Set MacApp     "`Catenate "{ShellDirectory}"MacApp_Folder`"
  29. Export MacApp
  30.  
  31. #    Execute the files should located in the Startup Items folder in the folder containing MacApp.
  32. For __Startup__i in `(Files -f -t TEXT "{MacApp}Startup Items:" || Set Status 0) ≥ dev:null`
  33.     Execute "{__Startup__i}"
  34. End
  35. Unset __Startup__i
  36.